package com.jumi.microservice.config;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.context.annotation.Configuration;

/**
 * @author Dirk
 * @Date 2020-07-20 13:44
 */
@Configuration
@RefreshScope
public class AliPayConfig {
    /**
     * 支付宝网关（固定）
     */
    @Value("${alipay.serverUrl}")
    private String serverUrl;

    /**
     * 应用id
     */
    @Value("${alipay.appId}")
    private String appId;

    /**
     * 应用私钥
     */
    @Value("${alipay.privateKey}")
    private String privateKey;

    /**
     * 支付宝公钥
     */
    @Value("${alipay.publicKey}")
    private String publicKey;

    /**
     * 支付宝异步回调地址，应使用https
     */
    @Value("${alipay.notifyUrl}")
    private String notifyUrl;

    /**
     * 支付宝H5异步回调地址，应使用https
     */
    @Value("${alipay.notifyH5Url}")
    private String notifyH5Url;

    /**
     * 支付宝H5同步回调地址，应使用https
     */
    @Value("${alipay.returnH5Url}")
    private String returnH5Url;

    /**
     * 支付宝H5同步支付成功地址，应使用https
     */
    @Value("${alipay.returnSuccessUrl}")
    private String returnSuccessUrl;

    /**
     * 支付宝H5同步支付失败地址，应使用https
     */
    @Value("${alipay.returnFailUrl}")
    private String returnFailUrl;

    public String getServerUrl() {
        return serverUrl;
    }

    public void setServerUrl(String serverUrl) {
        this.serverUrl = serverUrl;
    }

    public String getAppId() {
        return appId;
    }

    public void setAppId(String appId) {
        this.appId = appId;
    }

    public String getPrivateKey() {
        return privateKey;
    }

    public void setPrivateKey(String privateKey) {
        this.privateKey = privateKey;
    }

    public String getPublicKey() {
        return publicKey;
    }

    public void setPublicKey(String publicKey) {
        this.publicKey = publicKey;
    }

    public String getNotifyUrl() {
        return notifyUrl;
    }

    public void setNotifyUrl(String notifyUrl) {
        this.notifyUrl = notifyUrl;
    }

    public String getNotifyH5Url() {
        return notifyH5Url;
    }

    public void setNotifyH5Url(String notifyH5Url) {
        this.notifyH5Url = notifyH5Url;
    }

    public String getReturnH5Url() {
        return returnH5Url;
    }

    public void setReturnH5Url(String returnH5Url) {
        this.returnH5Url = returnH5Url;
    }

    public String getReturnSuccessUrl() {
        return returnSuccessUrl;
    }

    public void setReturnSuccessUrl(String returnSuccessUrl) {
        this.returnSuccessUrl = returnSuccessUrl;
    }

    public String getReturnFailUrl() {
        return returnFailUrl;
    }

    public void setReturnFailUrl(String returnFailUrl) {
        this.returnFailUrl = returnFailUrl;
    }
}
